package com.tj.bo.user.server.dao;

import com.fqgj.common.base.BaseMapper;
import com.tj.bo.user.server.entity.UserAccessEntity;

import java.util.List;

/**
 * User: anonymous
 * Date: 2020-06-10
 * Time: 15:40:06.928
 */

public interface UserAccessDao extends BaseMapper<UserAccessEntity> {

    UserAccessEntity selectUserAccessByUserCode(String userCode);

    UserAccessEntity selectUserAccessByToken(String realToken);

    UserAccessEntity selectUserAccessByLoginNumber(String appCode, Integer realFlag, String loginNumber);

    UserAccessEntity selectUserAccessByLoginNumberAndType(String appCode, Integer realFlag, String loginNumber, Integer registerType);

    UserAccessEntity selectUserAccessByAppCodeAndEmail(String appCode, Integer realFlag, String email);

    UserAccessEntity selectUserAccessByAppCodeAndOpenId(String appCode, Integer realFlag, Integer type, String openId);

    UserAccessEntity selectUserAccessByCustomerCode(String appCode, Integer realFlag, String customerCode);

    UserAccessEntity selectUserAccessByEmailPassword(String appCode, Integer realFlag, String email, String password);

    List<UserAccessEntity> selectUserAccessByDeviceId(String appCode, String deviceId, String channel);

    List<UserAccessEntity> selectUserAccessForAllRealUser();

    List<UserAccessEntity> selectRealUserAccessGroupByDeviceId(Integer deviceIdNum);

    List<UserAccessEntity> selectUserAccessInfoByDeviceId(String deviceId);

}